using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Web;

namespace NewRen.Models
{
    public class MessageBoard
    {
        public int ID { get; set; }

        /// <summary>
        /// 发布者
        /// </summary>
        [ForeignKey("FromUser")]
        public int FromUserID { get; set; }

        public virtual User FromUser { set; get; }

        /// <summary>
        /// 被留言者
        /// </summary>
        [ForeignKey("ToUser")]
        public int ToUserID { get; set; }

        public virtual User ToUser { set; get; }

        /// <summary>
        /// 描述
        /// </summary>
        public string Description { get; set; }

        /// <summary>
        /// 时间
        /// </summary>
        [Index]
        public DateTime Time  { get; set; }
    }
}
